filechooser: Make Ctrl-L work again
authorMatthias Clasen <mclasen@redhat.com>
Sat, 27 Mar 2021 13:53:43 +0000 (09:53 -0400)
committerMatthias Clasen <mclasen@redhat.com>
Sat, 27 Mar 2021 13:53:43 +0000 (09:53 -0400)
Prevent search from preempting the Ctrl-L shortcut
that is meant to show the location entry.

gtk/gtkfilechooserwidget.c

index 6f612c1c630dc84fb036dae0ff1571a03658caff..a666d55ca1d090c08360adf8c76a5c78e534356f 100644 (file)
@@ -7719,7 +7719,10 @@ captured_key (GtkEventControllerKey *controller,
   GtkFileChooserWidget *impl = data;
   gboolean handled;
 
-  if (impl->operation_mode == OPERATION_MODE_SEARCH)
+  if (impl->operation_mode == OPERATION_MODE_SEARCH ||
+      impl->operation_mode == OPERATION_MODE_ENTER_LOCATION ||
+      (impl->operation_mode == OPERATION_MODE_BROWSE &&
+       impl->location_mode == LOCATION_MODE_FILENAME_ENTRY))
     return GDK_EVENT_PROPAGATE;
 
   handled = gtk_event_controller_key_forward (controller, GTK_WIDGET (impl->search_entry));